package com.twu.biblioteca;

/**
 * Created with IntelliJ IDEA.
 * User: rwalters
 * Date: 01/02/13
 * Time: 15:33
 * To change this template use File | Settings | File Templates.
 */
public class Movie {
    public Movie(String _title, String _year, String _director, int _rating) {
        title = _title;
        year = _year;
        director = _director;
        rating = _rating;
    }

    public String title;
    public String year;
    public String director;
    public int rating;

    public String ratingToString() {
        if (rating < 1 || rating > 10) {
            return "N/A";
        }
        else {
            return Integer.toString(rating);
        }
    }
}
